<template xlang="wxml">
	<view class="container">
		<view style="display: flex;justify-content: center;align-items: center;height: 200upx;font-size: 50upx;font-weight: bold;">{{originData['供货单位']}}</view>
		<view style="display: flex;justify-content: center;align-items: center;height: 200upx;font-size: 50upx;font-weight: bold;">请截图并发给相关司机</view>
		<view class="qrimg">
			<view class="qrimg-i">
				<tki-qrcode 
				v-if="ifShow" 
				cid="qrcode1" 
				ref="qrcode" 
				:val="val" 
				:size="size" 
				:unit="unit" 
				:background="background" 
				:foreground="foreground" 
				:pdground="pdground" 
				:icon="icon" 
				:iconSize="iconsize" 
				:lv="lv" :onval="onval" 
				:loadMake="loadMake" 
				:usingComponents="true" 
				 />
			</view>
		 
		</view>
		 
	</view>
</template>
<script>
import tkiQrcode from '@/components/tki-qrcode/tki-qrcode.vue'
import {
	mapState
} from "vuex"
import qs from "qs"
export default {
	data() {
		return {
			originData:"",
			ifShow: false,
			val: '二维码', // 要生成的二维码值
			size: 700, // 二维码大小
			unit: 'upx', // 单位
			background: '#ffffff', // 背景色
			foreground: '#000000', // 前景色
			pdground: '#000000', // 角标色
			icon: '', // 二维码图标
			iconsize: 40, // 二维码图标大小
			lv: 3, // 二维码容错级别 ， 一般不用设置，默认就行
			onval: false, // val值变化时自动重新生成二维码
			loadMake: true, // 组件加载完成后自动生成二维码
			src: '' // 二维码生成后的图片地址或base64
		}
	},
	computed:{
		...mapState('account',['userInfo'])
	},
	methods: {
	
	},
	components: {
		tkiQrcode
	},
	onLoad: function () {
		let data = uni.getStorageSync("yuan_liao_qrcode_data");
		this.originData = data;
		uni.showLoading({
			title:"加载中"
		})
		setTimeout(()=>{
			data.account = this.userInfo.Account
 
			this.val = JSON.stringify(data);
			this.ifShow = true;
			uni.hideLoading()
		},2000)
		
	},
}
</script>

<style>
/* @import "../../../common/icon.css"; */
.container {
	display: flex;
	flex-direction: column;
	width: 100%;
}

.qrimg {
	display: flex;
	justify-content: center;
	
}
 

slider {
	width: 100%;
}

input {
	width: 100%;
	margin-bottom: 20upx;
}

.btns {
	display: flex;
	flex-direction: column;
	width: 100%;
}

button {
	width: 100%;
	margin-top: 10upx;
}
</style>
